#include<iostream>
using namespace std;
int k, n;
int main()
{
	int t;
	cin >> t;
	while (t--) {
		cin >> k >> n;
		if (n == k) {
			for (int i = 1; i <= n; i++) {
				cout << i << " ";
			}
			cout << endl;
			continue;
		}
		int ans = 1;
		int sum = 1;
		cout << 1 << " ";
		for (int i = 1; ans + i <= n; i++) {
			ans += i;
			sum++;
			//cout << ans << " ";
		}
		ans = 1;
		int sum1 = 1;
		if (sum >= k) {
			for (int i = 1; ans + i <= n && sum1 + 1 <= k; i++) {
				ans += i;
				sum1++;
				cout << ans << " ";
			}
		}
		else {
			int ans1 = 2;
			// 1 2 3
			for (int i = 0; i < k - sum; i++) {
				cout << ans1 << " ";
				ans1 += 1;
			}
			cout << ans1 << " ";
			ans = ans1;
			for (int i = 2; ans + i <= n; i++) {
				ans += i;
				cout << ans << " ";
			}
		}
		cout << endl;
	}
	return 0;
}
//1 2 4 7 11
//1 2 3 4 5 6 8 11